//
//  traveNotesDetailViewController.m
//  喜游迹
//
//  Created by niceDay on 16/1/3.
//  Copyright © 2016年 Leo_Lei. All rights reserved.
//

#import "traveNotesDetailViewController.h"
#import "AFNetworking.h"
#import "UIImageView+WebCache.h"
#import "UIViewExt.h"
@interface traveNotesDetailViewController ()

@end

@implementation traveNotesDetailViewController{
    
    NSDictionary *_dataDic;
    UIScrollView *_scrollView;
}

- (void)viewDidLoad {
    [super viewDidLoad];
    self.title = _notesModel.notesName;
    webView = [[UIWebView alloc]initWithFrame:CGRectMake(0, 0, kScreenWidth, kScreenHeight-64)];
    [self.view addSubview:webView];

    [self _loadData];
}

#pragma mark - 解析数据

- (void)_loadData{
    //创建url
    NSString *url = [NSString stringWithFormat:@"http://e-traveltech.com/travelNotes/page/index?travel_id=%@",_notesModel.notesId];
    NSURL *urlStr = [NSURL URLWithString:url];
    [webView loadRequest:[NSURLRequest requestWithURL:urlStr]];
    
    //自适应
    webView.scalesPageToFit = YES;
    webView.delegate = self;
}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

@end
